package com.example.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDate;
import java.time.LocalDateTime;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class Leaves {
    //编号
    @TableId(value = "id",type = IdType.AUTO)
    private Integer id;

    //开始时间
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private LocalDate beginTime;

    //结束时间
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private LocalDate endTime;

    //请假天数
    @TableField(exist = false)
    private  long day;

    //审核人id
    private Integer examineId;

    //状态
    private String status;

    //审批意见
    private String comment;

    //创建人id
    private Integer createId;

    // 处理人姓名
    @TableField(exist = false)
    private String examineName;

    // 创建者姓名
    @TableField(exist = false)
    private String creatorName;

    // 请假类型
    private String leaveType;

    // 请假详细
    private  String leaveDetails;
}
